@import "@/style/scss/index.scss";

.timeline-wrapper {
  display: flex;
  flex-direction: row;
  //overflow: scroll;
  align-items: center;
  padding-left: 100px;
  overflow-y: hidden;
  overflow-x: hidden;
  .timeline-grid {
    width: 373px;
    height: -webkit-fill-available;
    .grid-date {
      margin-top: 272px;
      margin-left: -135px;
      width: 92px;
      height: 92px;
      border-radius: 50%;
      float: left;
      span {
        text-align: center;
        align-items: center;
        width: 92px;
        height: 92px;
        font-size: 24px;
        font-weight: bold;
        color: #FFFFFF;
        display: table-cell;
        vertical-align: middle;
      }
      &.yellow {
        background: linear-gradient(-24deg, #FAB63C, #FFE475);
      }
      &.green {
        background: linear-gradient(-24deg, #1AAD39, #C3F39C);
      }
      &.purple {
        background: linear-gradient(-24deg, #5477FF, #BAAAFF);
      }
      &.blue {
        background: linear-gradient(-24deg, #67A8F1, #00FFD8);
      }
    }

    .grid-name-box {
      margin-left: -66px;
      float: left;
      width: 200px;
      height: 56px;
      position: relative;
      .grid-name {
        border-radius: 28px;
        min-width: 200px;
        min-height: 50px;
        max-height: 64px;
        max-width: 220px;
        padding: 8px 20px 8px 20px;
        display: flex;
        span {
          line-height: 26px;
          width: fit-content;
          height: fit-content;
          text-align: center;
          align-items: center;
          font-size: 24px;
          font-weight: bold;
          color: #FFFFFF;
          vertical-align: middle;
          margin: auto;
          position: relative;
          overflow:hidden;
          text-overflow:ellipsis;
          display:-webkit-box;
          -webkit-box-orient:vertical;
          -webkit-line-clamp:2;
        }
      }
      &.yellow {
        margin-top: 92px;
        .grid-name {
          background: linear-gradient(0deg, #F4B740, #FFE373);
          box-shadow: 0px 24px 87px 0px rgba(23, 88, 160, 0.36);
        }
      }
      &.green {
        margin-top: 482px;
        .grid-name {
          background: linear-gradient(0deg, #2AB342, #A4DC8F);
          box-shadow: 0px 24px 87px 0px rgba(23, 88, 160, 0.36);
        }
      }
      &.purple {
        margin-top: 92px;
        .grid-name {
          background: linear-gradient(0deg, #5B7AFE, #B4A7FF);
          box-shadow: 0px 24px 87px 0px rgba(23, 88, 160, 0.36);
        }
      }
      &.blue {
        margin-top: 482px;
        .grid-name {
          background: linear-gradient(0deg, #459BE3, #38F2E0);
          box-shadow: 0px 24px 87px 0px rgba(23, 88, 160, 0.36);
        }
      }
    }

    .grid-v-line {
      width: 8px;
      height: 80px;
      float: right;
      margin-left: 40px;
      position: absolute;
      &.yellow {
        margin-top: 193px;
        background: #FFE171;
        .grid-v-round {
          margin-left: -6px;
          margin-top: -16px;
          width: 10px;
          height: 10px;
          border: 5px solid #FFE171;
          border-radius: 50%;
        }
      }
      &.green {
        margin-top: 362px;
        background: #C3F39C;
        .grid-v-round {
          margin-left: -6px;
          margin-top: 78px;
          width: 10px;
          height: 10px;
          border: 5px solid #C3F39C;
          border-radius: 50%;
        }
      }
      &.purple {
        margin-top: 193px;
        background: #5477FF;
        .grid-v-round {
          margin-left: -6px;
          margin-top: -16px;
          width: 10px;
          height: 10px;
          border: 5px solid #5477FF;
          border-radius: 50%;
        }
      }
      &.blue {
        margin-top: 362px;
        background: #00FFD8;
        .grid-v-round {
          margin-left: -6px;
          margin-top: 78px;
          width: 10px;
          height: 10px;
          border: 5px solid #00FFD8;
          border-radius: 50%;
        }
      }
    }

    .grid-h-line {
      width: 290px;
      height: 8px;
      margin-left: 91px;
      margin-top: 312px;
      &.yellow {
        background: #FFE171;
      }
      &.green {
        background: #C3F39C;
      }
      &.purple {
        background: #5477FF;
      }
      &.blue {
        background: #00FFD8;
      }
    }

    .grid-img {
      width: 260px;
      min-height: 260px;
      float: right;
      margin-right: -121px;
      display: flex;
      &.yellow {
        margin-top: -350px;
      }
      &.green {
        margin-top: 69px;
      }
      &.purple {
        margin-top: -350px;
      }
      &.blue {
        margin-top: 69px;
      }
      &:hover {
        cursor: pointer;
      }
      img {
        width: 100%;
        z-index: 2;
      }
      .button-box {
        display: flex;
        flex-direction: column;
        margin-left: 20px;
        z-index: 1;
        .button-share-item {
          margin-top: 50px;
          width: 40px;
          height: 40px;
          background: linear-gradient(-24deg, #FC8A63, #EFD469);
          border-radius: 20px;
          img {
            height: 24px;
            width: 24px;
          }
        }
        .button-edit {
          margin-top: 20px;
          width: 40px;
          height: 40px;
          border-radius: 20px;
          background: linear-gradient(-24deg, #2BA886, #61E1CC);
          img {
            height: 24px;
            width: 24px;
          }
        }
        .button-delete {
          margin-top: 20px;
          width: 40px;
          height: 40px;
          background: linear-gradient(-24deg, #FF606B, #FF8585);
          border-radius: 20px;
          img {
            height: 24px;
            width: 24px;
          }
        }
      }
    }

  }
  &:hover {
    overflow-x: overlay;
  }
}

::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

::-webkit-scrollbar-track {
  border-radius: 10px;
  background-color: #91c4fd;
}

::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background-color: white;
}

::-webkit-scrollbar-track {
  margin-left: 25vw;
  margin-right: 25vw;
}
